<template>
	<view>
		<p v-html="info.title"></p>
		<image :src="info.pic" mode=""></image>
		<view v-html="info.content"></view>
	</view>
</template>

<script>
	export default {
		
		data() {
			return {
				info:{}, //文章详情
			}
		},
		methods: {
			
		},
		onLoad(options) {
			console.log(options);  // {id:xxxx}
			let {id} = options;
			uni.showLoading({
				title:"加载中"
			})
			// 请求文章详情
			uni.request({
				url:"https://api.it120.cc/small4/cms/news/detail?id=" + id,
				success:(res)=>{
					console.log(res);
					this.info = res.data.data
				},
					
				complete: ()=>{
					uni.hideLoading()
				}
			})
		}
	}
</script>

<style>

</style>
